<template>
  <!-- total:总条数
     current-page 当前页
     page-size 每页多少条数  -->
  <el-pagination
    @current-change="handleCurrentChange"
    background
    layout="prev, pager, next"
    :total="total"
    :current-page="page"
    :page-size="10"
  >
  </el-pagination>
</template>
<script>
import axios from 'axios'
export default {
  name: "pagination",
  data() {
    return {
      // 总条数
      total: 10,
      // 页码
      page: 1
    };
  },
  created() {

  },
  methods: {
    handleCurrentChange(val) {
      console.log(`当前页: ${val}`);
     
    }
  }
};
</script>

<style>
</style>